package com.whtq.front.common.exception;

import com.whtq.front.common.basics.WHTQReturnCode;
import lombok.Data;

@Data
public class WHTQException extends RuntimeException {

    private String code;
    private String message;

    private WHTQReturnCode whtqReturnCode;


    public WHTQException(WHTQReturnCode code) {
        this.message = code.getMessage();
        this.code = code.getCode();
        this.whtqReturnCode = whtqReturnCode;
    }

    public WHTQException(String code, String msg) {
        this.message = msg;
        this.code = code;
    }

}
